/**
 * @api {post} /users/login 用户登录
 * @apiName login
 * @apiGroup users
 *
 * @apiParam {String} username 用户名.
 * @apiParam {String} password 用户密码.
 *
 * @apiSuccess {Number} code 状态码.
 * @apiSuccess {String} msg 信息.
 * @apiSuccess {Object} data 响应数据.
 *
 * @apiSuccessExample 成功-响应:
 *     HTTP/1.1 200 OK
 */

/**
 * @api {get} /users/verify 校验auth
 * @apiName verify
 * @apiGroup users
 *
 * @apiParam {String} user_name 用户名.
 *
 * @apiHeader {String} authorization auth_token
 *
 * @apiSuccess {Number} code 状态码.
 * @apiSuccess {String} msg 信息.
 * @apiSuccess {Object} data 响应数据.
 *
 * @apiSuccessExample 成功-响应:
 *     HTTP/1.1 200 OK
 */

/**
 * @api {get} /users 获取用户列表
 * @apiName users
 * @apiGroup users
 *
 * @apiHeader {String} authorization auth_token
 *
 * @apiParam {String} [username] 用户名【模糊匹配】(可选).
 * @apiParam {String} [class_grade] 班级【模糊匹配】(可选).
 * @apiParam {String} [role] 角色【模糊匹配】(可选).
 * @apiParam {Number} [page=1] 页数【默认1】(可选).
 * @apiParam {Number} [pagesize=5] 每页条数【默认5】(可选).
 *
 * @apiSuccess {Number} code 状态码.
 * @apiSuccess {String} msg 信息.
 * @apiSuccess {Object} data 响应数据.
 *
 * @apiSuccessExample 成功-响应:
 *     HTTP/1.1 200 OK
 */

/**
 * @api {post} /users/insert 添加新用户
 * @apiName insert
 * @apiGroup users
 *
 * @apiHeader {String} authorization auth_token
 *
 * @apiParam {String} username 用户名【必填】.
 * @apiParam {String} password 密码【必填】.
 * @apiParam {Number} [sex=0] 性别【0:默认未知,1:男,2:女】.
 * @apiParam {String} [tel] 手机号【可选】.
 * @apiParam {String} [class_grade] 班级【可选】.
 * @apiParam {String} [organization] 社团【可选】.
 * @apiParam {Number} [state=1] 状态【1:启用,0:禁用】(默认启用).
 * @apiParam {String} [role=用户] 角色【'用户','管理员'】(默认为 用户)
 * @apiParam {Date} [add_time] 入社时间【可选】
 *
 * @apiSuccess {Number} code 状态码.
 * @apiSuccess {String} msg 信息.
 * @apiSuccess {Object} data 响应数据.
 *
 * @apiSuccessExample 成功-响应:
 *     HTTP/1.1 200 OK
 */

/**
 * @api {put} /users/:id 修改用户信息
 * @apiName updateuser
 * @apiGroup users
 *
 * @apiHeader {String} authorization auth_token
 *
 * @apiParam {String} id 用户ID(必填).
 * @apiParam {String} [password] 密码【可选】.
 * @apiParam {Number} [sex=0] 性别【0:默认未知,1:男,2:女】.
 * @apiParam {String} [tel] 手机号【可选】.
 * @apiParam {String} [class_grade] 班级【可选】.
 * @apiParam {String} [organization] 社团【可选】.
 * @apiParam {Number} [state=1] 状态【1:启用,0:禁用】(可选，默认启用).
 * @apiParam {String} [role=用户] 角色【'用户','管理员'】(可选，默认用户)
 * @apiParam {Date} [add_time] 入社时间【可选】
 *
 * @apiSuccess {Number} code 状态码.
 * @apiSuccess {String} msg 信息.
 * @apiSuccess {Object} data 响应数据.
 *
 * @apiSuccessExample 成功-响应:
 *     HTTP/1.1 200 OK
 */

/**
 * @api {delete} /users/:id 删除用户
 * @apiName delete
 * @apiGroup users
 *
 * @apiHeader {String} authorization auth_token
 *
 * @apiParam {String} id 用户ID(必填).
 *
 * @apiSuccess {Number} code 状态码.
 * @apiSuccess {String} msg 信息.
 * @apiSuccess {Object} data 响应数据.
 *
 * @apiSuccessExample 成功-响应:
 *     HTTP/1.1 200 OK
 */


/**
 * @api {get} /users/:id 获取单个用户信息
 * @apiName getUser
 * @apiGroup users
 *
 * @apiHeader {String} authorization auth_token
 *
 * @apiParam {String} id 用户ID(必填).
 *
 * @apiSuccess {Number} code 状态码.
 * @apiSuccess {String} msg 信息.
 * @apiSuccess {Object} data 响应数据.
 *
 * @apiSuccessExample 成功-响应:
 *     HTTP/1.1 200 OK
 */

/**
 * @api {put} /users/editpwd/:id 修改密码
 * @apiName editpwd
 * @apiGroup users
 *
 * @apiHeader {String} authorization auth_token
 *
 * @apiParam {String} id 用户ID(必填).
 * @apiParam {String} password 用户密码.
 * @apiParam {String} newpassword 用户新密码.
 *
 * @apiSuccess {Number} code 状态码.
 * @apiSuccess {String} msg 信息.
 * @apiSuccess {Object} data 响应数据.
 *
 * @apiSuccessExample 成功-响应:
 *     HTTP/1.1 200 OK
 */